<?php
/*------------------------------------------------------------------------

# TZ Portfolio Extension

# ------------------------------------------------------------------------

# author    TranLamTemPlaza

# copyright Copyright (C) 2012 templaza.com. All Rights Reserved.

# @license - http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL

# Websites: http://www.templaza.com

# Technical Support:  Forum - http://templaza.com/Forum

-------------------------------------------------------------------------*/

defined('_JEXEC') or die;

defined('_JEXEC') or die;
$doc = JFactory::getDocument();
$doc->addStyleSheet('modules/mod_tz_teaser_slide/css/style.css');
$doc->addStyleSheet('modules/mod_tz_teaser_slide/showbizpro/css/settings.css');
$doc->addStyleSheet('modules/mod_tz_teaser_slide/showbizpro/fancybox/jquery.fancybox.css?v=2.1.3');
$doc->addScript('modules/mod_tz_teaser_slide/showbizpro/fancybox/jquery.fancybox.pack.js?v=2.1.3');
$doc->addScript('modules/mod_tz_teaser_slide/showbizpro/js/jquery.themepunch.showbizpro.min.js');

?>

<!-- DEMO X. -->
<div id="example10" class="showbiz-container fullwidth nopaddings ">

    <!--	THE PORTFOLIO ENTRIES	-->
    <div class="showbiz sb-modern-skin">
        <!-- THE OVERFLOW HOLDER CONTAINER, DONT REMOVE IT !! -->
        <div class="overflowholder">
            <!-- LIST OF THE ENTRIES -->
            <ul>

                <?php
                for($i=0;$i<count($rows);$i++){
                ?>
                    <!-- AN ENTRY HERE WITH PREDEFINED MEDIA SKIN-->
                    <li class="sb-modern-skin">

                        <?php
                        if($show_image==1){
                        ?>
                            <!-- THE MEDIA HOLDER -->
                            <div class="mediaholder">
                                <div class="mediaholder_innerwrap">
                                    <img alt="" src="<?php echo JUri::base().substr($rows[$i] ->images,0,69)."_L.".substr($rows[$i] ->images,70,80);?>">
                                </div>
                            </div><!-- END OF MEDIA HOLDER -->
                        <?php
                        }
                        ?>

                        <div class="darkhover"></div>

                        <div class="detailholder">
                            <?php
                            if($show_title==1){
                            ?>
                                <div class="showbiz-title"><?php echo $rows[$i] ->title;?></div>
                            <?php
                            }
                            ?>
                            <div class="divide20"></div>
                            <?php
                            if($show_introtext==1){
                            ?>
                                <p class="excerpt">
                                    <?php echo substr($rows[$i] ->introtext,0,100);?>
                                <div class="divide20"></div>
                                </p>
                            <?php
                            }
                            ?>
                            <!-- THE POST INFOS AND READ MORE BUTTON -->
                            <div class="sb-post-details leftfloat"><span class="rm15">NEWS</span><span class="rm15">33 COMMENTS</span></div>
                            <div class="sb-readmore rightfloat"><a href="<?php echo $rows[$i] ->link;?>">READ MORE</a></div>
                            <div class="sb-clear"></div><!-- END OF POST INFOS AND READ MORE BUTTON -->
                        </div>

                    </li><!-- END OF ENTRY -->
                <?php
                }
                ?>

            </ul>
            <div class="sbclear"></div>
        </div> <!-- END OF OVERFLOWHOLDER -->
        <div class="sbclear"></div>
    </div>
</div><!-- END OF DEMO -->


<div class="divide30"></div>


<script type="text/javascript">

    jQuery(document).ready(function() {

        jQuery('#example10').showbizpro({
            dragAndScroll:"<?php if($drag_and_scroll==1){echo "on";} else echo "off";?>",
            visibleElementsArray:[3,3,2,1],
            carousel:"<?php if($carousel==1){echo "on";} else echo "off";?>",
            entrySizeOffset:0,
            allEntryAtOnce:"<?php if($all_entry_at_once==1){echo "on";} else echo "off";?>",
            ytMarkup:"<iframe src='http://www.youtube.com/embed/%%videoid%%?hd=1&amp;wmode=opaque&amp;autohide=1&amp;showinfo=0&amp;autoplay=1'></iframe>",
            vimeoMarkup:"<iframe src='http://player.vimeo.com/video/%%videoid%%?title=0&amp;byline=0&amp;portrait=0;api=1&amp;autoplay=1'></iframe>",
            rewindFromEnd:"<?php if($rewind_from_end==1){echo "on";} else echo "off";?>",
            autoPlay:"<?php if($auto_play==1){echo "on";} else echo "off";?>",
            delay:<?php echo $delay;?>,
            speed:<?php echo $speed;?>
        });

        // THE FANCYBOX PLUGIN INITALISATION
        jQuery(".fancybox").fancybox();

    });

</script>